<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>layui</title>
<META HTTP-EQUIV="pragma" CONTENT="no-cache"> 
<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache, must-revalidate"> 
<META HTTP-EQUIV="expires" CONTENT="0">
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport"content="width=device-width, initial-scale=1, maximum-scale=1">
<script src="../../../js/angular.js" charset="utf-8"></script>
<link rel="stylesheet" href="../../../layui/layui/css/layui.css" media="all">
<script type="text/javascript" src="../../../layui/layui/lay/modules/layer.js"></script>
<script src="../../../layui/layui/jquery-3.2.1.min.js" charset="utf-8"></script>
<script src="../../../layui/layui/layui.js" charset="utf-8"></script>
<script type="text/javascript" src="fy.js"></script>
	<script type="text/javascript" src="../../../layui/lay/modules/layer.js"></script>

</head>
<body>
<div class="sysNotice col">
<div  action="">
	 <blockquote class="layui-elem-quote news_search" style="text-align: left;">个人基数变更
	</blockquote>
	</div>
			</div>
			<!-- <img src="/file/image/20180518134313.png"   /> -->
	<div ng-app="myApp" ng-controller="customersCtrl" align="center">
				<loading>查询中请稍后</loading>


		<div id="bj" ng-hide="hjqcbj1">
		<div class="layui-inline" align="center">
	      <label class="layui-form-label" style="width: 80px" >年月:</label>
	      <div class="layui-input-inline">
	        <input class="layui-input" id="test8" type="text" ng-model="xmc" >
	      </div>
	    </div>
	    
  		<div class="layui-inline" align="center">
	        <input ng-click="chaxun()" type="button" class="layui-btn layui-btn-primary" value="查&nbsp;&nbsp;&nbsp;&nbsp;询">
	         <input ng-click="zjjl($index)" type="button" class="layui-btn layui-btn-primary" value="增加新记录">
	    </div>
				<table class="layui-table" style="width:90%">
					<tr align="center" style="background-color:#f1f1f1">
						<td ng-show=false>当前行数</td>
						<td>姓名</td>
						<td>工资基数</td>
						<td>个人月缴存额</td>
						<td>单位月缴存额</td>
						<td>个人缴存比例</td>
						<td>单位缴存比例</td>
						<td>个人账号</td>
						<td>操作</td>

					</tr>
					<tr ng-repeat="x in names" align="center">
						<td ng-if="$odd" ng-show=false style="background-color:#f1f1f1">{{
							$index+1 }}</td>
						<td ng-if="$even" ng-show=false>{{ $index+1 }}</td>
						<td ng-if="$odd" style="background-color:#f1f1f1">{{
							x.XINGMING }}</td>
						<td ng-if="$even">{{ x.XINGMING }}</td>
						<td ng-if="$odd" style="background-color:#f1f1f1">{{ x.GZJS
							}}</td>
						<td ng-if="$even">{{ x.GZJS }}</td>
						<td ng-if="$odd" style="background-color:#f1f1f1">{{ x.GRJCE
							}}</td>
						<td ng-if="$even">{{ x.GRJCE }}</td>
						<td ng-if="$odd" style="background-color:#f1f1f1">{{ x.DWJCE
							}}</td>
						<td ng-if="$even">{{ x.DWJCE }}</td>
						<td ng-if="$odd" id="grzh" style="background-color:#f1f1f1">{{
							x.GRJCBL }}</td>
							<td ng-if="$even">{{ x.GRJCBL }}</td>
						<td ng-if="$odd" style="background-color:#f1f1f1">{{ x.DWJCBL
							}}</td>
						<td ng-if="$even">{{ x.DWJCBL }}</td>
						<td ng-if="$odd" id="grzh" style="background-color:#f1f1f1">{{
							x.GRZH }}</td>
						<td ng-if="$even">{{ x.GRZH }}</td>
						
						<td ng-if="$odd" style="background-color:#f1f1f1"><a
							style="color: red;" ng-click="bj111($index)" href="#">查看图片</a>
						</td>
						<td ng-if="$even"><a
							style="color: red;" ng-click="bj111($index)" href="#">查看图片</a>
						</td>
					</tr>
				</table>
			
			<div class="layui-btn-group">
				<button class="layui-btn layui-btn-primary layui-btn-sm"
					ng-click="Sy()">首页</button>
				<button class="layui-btn layui-btn-primary layui-btn-sm"
					ng-click="Previous()">上一页</button>
				<button ng-repeat="page in pageList"
					class="layui-btn layui-btn-primary layui-btn-sm "
					ng-click="selectPage(page)">{{page}}</button>
				<button class="layui-btn layui-btn-primary layui-btn-sm"
					ng-click="Next()">下一页</button>
				<button class="layui-btn layui-btn-primary layui-btn-sm"
					ng-click="Wy()">尾页</button>
				<button class="layui-btn layui-btn-primary layui-btn-sm ">{{selPage}}/{{pages}}</button>
			</div>
		</div>
	
	<script type="text/javascript">
	 //查询

		function getPath() {
			return 'http://' + location.host;
		};
		var a;
		var app = angular.module('myApp', []);
		 app.directive('loading', function(){  
		        return {  
		            restrict: 'E',  
		            transclude: true,  
		            template: '<div ng-show="loading" class="loading" id="allDiv"  style="position:fixed; top:0px; left:0px; width:100%; height:100%; display:none; background-color:#000; opacity: 0.5; z-index:99999;">'  
		            +'<img alt="" src="../../../layui/layui/img/jz.gif" style="vertical-align: middle;width:30px; height:30px; position: absolute; top:50%; left:50%; margin-top: -50px; margin-left:-50px;"/>'
		            +'</div>',  
		            link: function (scope, element, attr) {  
		                scope.$watch('loading', function (val) {  
		                    if (val){  
		                        document.getElementById("allDiv").style.display = "block";  
		                    }else{  
		                        document.getElementById("allDiv").style.display = 'none';  
		  
		                    }  
		                });  
		            }  
		        };
		    }); 
		    
		     
		    app.controller('customersCtrl', function($scope, $http) {
		     $scope.setLoading =function(){  
			    if($scope.loading ==undefined || $scope.loading ==false){  
			        $scope.loading=true;  
			    }else{  
			        $scope.loading=false;  
			    };
			};
  	 $scope.bj111 =function(index) {
  	 var cc=($scope.selPage-1)*20+index+1;
  	 var ID=$scope.data[cc-1].ID;
  	 var type=28;
  	 var GRZH=123445678901;
  	 		layer.open({ 
type: 2,  
 title: '查看上传图片',
area: ['100%', '100%'],
content: getPath()+'/wsyyt/dwwsyyt/dw/gjjhbj/tp1.html?ID='+ID+'&GRZH='+GRZH+'&type='+type //这里content是一个URL,如果不显示滚动条就使用上面content: ['test/guodu.html', 'no']
});
     			 };  
     			 	
     			  $scope.zjjl =function(index) {	
     			  if($("#test8").val()==""||$("#test8").val()==null)
     			  {
							layer.alert('提示：请选择年月', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
								     }});	
								     return;
     			  }
           			layer.open({
		                    type: 2,
		                    title: '增加记录',
		                    shadeClose: true,
		                    shade: false,
		                    maxmin: true, //开启最大化最小化按钮
		                    area: ['100%', '100%'],
		                    content: getPath()+'/wsyyt/dwwsyyt/dw/gjjhbj/grjsbg.html?NIANYUE='+$("#test8").val()
		                });
		                
					
     			 }; 
  
  			layui.use('layer', function(){
  var layer = layui.layer;
  
});  
  
  $scope.chaxun = function () {
  if($("#test8").val()==""||$("#test8").val()==null)
  {
  	layer.alert('提示：请选择查询年月', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
								     }});
								     return;
  
  }
  	$scope.setLoading();
       			$scope.params={NIANYUE:$("#test8").val()};
			$http({
				url:getPath() + "/wsyyt/dwbjhjqccontroller/bghxx",
				contentType:"text/html;charset=utf-8",
				method:'post',
				params:$scope.params,	
			}).then(
							function(res) {
							 if(res.data.msg==null)
								 {
								 	layer.msg("登陆失效请重新登陆");
									setTimeout(function () {
										window.top.location.href=res.data;
									}, 1500);
									return;
								 }
								$scope.data = res.data.data;//自己打断点看格式:[{},{}]
								$scope.setLoading();
									if(res.data.msg!='成功')
							layer.alert('提示：当月无基数变更信息', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
								     }});				
								a = res.data.CNT;
								 feny($scope.data);
								   });
  
  }
			});
						layui.use('layer', function(){
  var layer = layui.layer;
  
});  
		layui.use('laydate', function(){
	  var laydate = layui.laydate;
	  laydate.render({
	    elem: '#test8'
	    ,type: 'month'
	  });
	});	
</script>
</body>
</html>